package player.ui.video;

import java.awt.Color;
import java.awt.GradientPaint;
import java.awt.Graphics;
import java.awt.Graphics2D;
import java.awt.LinearGradientPaint;
import java.awt.Paint;
import java.awt.RenderingHints;

import javax.swing.JButton;
import javax.swing.JComponent;

public class GlassPanelTop extends JComponent{
	private static final long serialVersionUID = -1454085200657862507L;
	
	GlassPanelTop(){
		super();
	}
	
	public void paint(Graphics g){
		 Graphics2D g2 = (Graphics2D) g;
	        Paint oldPaint=g2.getPaint();
	        g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
	        
	        int arc=15;
	        Paint p= new LinearGradientPaint(0, 0, 0, getHeight(),
	                new float[] { 0.0f,1.0f },
	                new Color[] { new Color(250,250,250,50),
	                              new Color(250,250,250,50)});
	        g2.setPaint(p);
	        g2.fillRoundRect(0, 0, getWidth(), getHeight(),arc,arc);
	        
	        g2.setColor(new Color(250,250,250,150));
	        g2.drawRoundRect(1, 1, getWidth()-2, getHeight()+12,arc,arc);
	       
	        
	        g2.setPaint(oldPaint);
	}
	
	
}
